<?
//根据传递过来的项，读取detail表格的内容
//item项的名称
//str传递过来的值
function get_detail_by_item_huanqiao($item,$str)
{
global $table_Prefix;
global $sys_list_table;

//设置需要搜索的表格的前缀后缀
$table_Suffix = $sys_list_table;
$table = $table_Prefix . $table_Suffix;
//设置需要搜索的表格的前缀后缀

$result = mysql_query("SELECT * FROM $table where $item = '$str' ");

while ($row = mysql_fetch_array($result)) {
    $detail['name']                 = $row['name'];
    $detail['xilie']                = $row['xilie'];
    $detail['kelichicun']           = $row['kelichicun'];
    $detail['qty']                  = $row['qty'];
    $detail['zhuangxiangdanwei']    = $row['zhuangxiangdanwei'];
    $detail['gongyi']               = $row['gongyi'];
    $detail['zhongliangshuzhi']     = $row['zhongliangshuzhi'];
    $detail['zhongliangdanwei']     = $row['zhongliangdanwei'];
    $detail['chang']                = $row['chang'];
    $detail['kuan']                 = $row['kuan'];
    $detail['zuididinghuoliang']    = $row['zuididinghuoliang'];
    $detail['zuidiqidingfangshu']   = $row['zuidiqidingfangshu'];
    $detail['yixiangpingfangshuzi'] = $row['yixiangpingfangshuzi'];
    $detail['pingfangdanwei']       = $row['pingfangdanwei'];
    $detail['xiliemingcheng']       = $row['xiliemingcheng'];
    $detail['caizhi']       = $row['caizhi'];
}

return $detail;

}
?>

